
import requests
import os

url = 'https://g0.gph.netease.com/ngsocial/community/stzb/cfg/hero_extra.json?gameid=g10'

heros = requests.get(url)



for hero in heros.json():
    hero_url = f"https://g0.gph.netease.com/ngsocial/community/stzb/cn/cards/cut/card_small_{hero['id']}.jpg?gameid=g10"
    print(hero)
    with open(f"static/率土之滨/{hero['name']}.jpg",'wb') as f:
        f.write(requests.get(hero_url).content)


















































